<?php
/*
If you would like to edit this file, copy it to your current theme's directory and edit it there.
Theme My Login will always look in your theme's directory first, before using this default template.
*/
if (isset($_REQUEST['checkemail']) && $_REQUEST['checkemail'] == 'confirm' && $_REQUEST['user_login']) {
	$register_links = $template->get_action_links(array( 'login' => false, 'register' => false));
	?>
		<div class="login" id="theme-my-login<?php $template->the_instance(); ?>">
			<ul class="login-lostpwd-step">
				<li><?php _e('Send verification email', 'theme-my-login');?></li>
				<li><?php _e('Set new password', 'theme-my-login');?></li>
				<li><?php _e('Password changed successfully', 'theme-my-login');?></li>
			</ul>
			<form name="registerform" id="registerform<?php $template->the_instance(); ?>" action="<?php $template->the_action_url( 'register' ); ?>" method="post">
				<div class="msg-info1"><?php _e('Your registered email is:', 'theme-my-login');?><i class="i-reds"><?php echo $_REQUEST['user_login'];?></i></div>
				<?php if (!isset($_REQUEST['resend'])):?>
				<div class="msg-info2"><?php _e('Verify Mail has occurred successfully, log on to the mailbox, click on the link inside the email to complete the verification', 'theme-my-login'); ?></div>
				<?php else :?>
				<?php $_POST['user_login'] = $_REQUEST['user_login']; ?>
				<?php Theme_My_Login::retrieve_password();?>
				<div class="msg-info2"><?php _e('Having been re-send verification email', 'theme-my-login');?></div>
				<?php endif;?>
				<div class="msg-info3">
					<div class="msg-info1"><?php _e('Did not receive the verify email?', 'theme-my-login');?></div>
					<div class="msg-info-content">
					<div class="msg-p">1&nbsp;,&nbsp;&nbsp;<?php _e('Go to spam, spam directory look for this email', 'theme-my-login');?></div>
					<div class="msg-p">2&nbsp;,&nbsp;&nbsp;<a target="_blank" href="<?php echo add_query_arg(array('resend'=>'true'));?>"><?php _e('Resend verification email', 'theme-my-login');?></a></div>
					<div class="msg-p">3&nbsp;,&nbsp;&nbsp;<?php _e('User name or email write error,', 'theme-my-login')?><a target="_blank" href="<?php echo $register_links[0]['url'];?>"><?php _e('Rewrite', 'theme-my-login');?></a></div>
					</div>
				</div>
			</form>
			<?php /*$template->the_action_links( array( 'register' => false ) );*/ ?>
		</div>
		<?php 
} else {
?>
<div class="login" id="theme-my-login<?php $template->the_instance(); ?>">
	<?php $template->the_action_template_message( 'lostpassword' ); ?>
	<?php $template->the_errors(); ?>
	
	<ul class="login-lostpwd-step">
	<li><?php _e('Send verification email', 'theme-my-login');?></li>
	<li><?php _e('Set new password', 'theme-my-login');?></li>
	<li><?php _e('Password changed successfully', 'theme-my-login');?></li>
	</ul>
	<form name="lostpasswordform" id="lostpasswordform<?php $template->the_instance(); ?>" action="<?php $template->the_action_url( 'lostpassword' ); ?>" method="post">
		<p><label class="user_login_lostpwd<?php $template->the_instance(); ?>"><?php _e( 'Please input Username or E-mail:', 'theme-my-login'); ?></label></p>
		<p>
			<input type="text" name="user_login" id="user_login_lostpwd<?php $template->the_instance(); ?>" class="input" value="<?php $template->the_posted_value( 'user_login' ); ?>" size="20" />
		</p>

		<?php do_action( 'lostpassword_form' ); ?>

		<p class="submit">
			<input type="submit" name="wp-submit" id="wp-submit-lostpwd<?php $template->the_instance(); ?>" value="<?php esc_attr_e( 'Get New Password' ); ?>" />
			<input type="hidden" name="redirect_to" value="<?php $template->the_redirect_url( 'lostpassword' ); ?>" />
			<input type="hidden" name="instance" value="<?php $template->the_instance(); ?>" />
			<input type="hidden" name="action" value="lostpassword" />
		</p>
	</form>
</div>
<?php }?>